<template>
  <div class="container">
    <header>
      <h1 class="main-title">图拉丁个人OJ系统-主页</h1>
    </header>

    <main>
      <section class="intro-section">
        <h2 class="section-title">名称由来</h2>
        <p class="content-text">
          图拉丁（Tualatin）源自百度贴吧「图拉丁吧」。
          将这里打造成IT技术爱好者的乐园是我的目的，我将秉承着「技术无贵贱，人人皆可图」的开放精神来进行创作。
        </p>
      </section>

      <section class="platform-intro">
        <h2 class="section-title">平台简介</h2>
        <div class="workflow">
          <p class="content-text">本系统是一个专业的在线代码评测平台，提供：</p>
          <ol class="feature-list">
            <li>管理员创建编程题目及测试用例</li>
            <li>用户在线编写并提交代码解决方案</li>
            <li>安全沙箱执行代码并返回运行结果</li>
            <li>实时评测反馈与历史提交记录查询</li>
          </ol>
        </div>
      </section>

      <nav class="navigation">
        <router-link to="/questions" class="nav-link">题目列表</router-link>
        <router-link to="/question_submit" class="nav-link"
          >提交记录
        </router-link>
        <router-link to="/competitions" class="nav-link">竞赛列表</router-link>
      </nav>
    </main>
  </div>
</template>

<script>
export default {
  name: "IndexPage",
};
</script>

<style scoped>
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem;
}

.main-title {
  color: #2c3e50;
  text-align: center;
  font-size: 2.5rem;
  margin-bottom: 2rem;
  border-bottom: 3px solid #42b983;
  padding-bottom: 1rem;
}

.section-title {
  color: #34495e;
  font-size: 1.8rem;
  margin: 1.5rem 0;
}

.content-text {
  line-height: 1.8;
  color: #4a5568;
  margin-bottom: 1.2rem;
}

.feature-list {
  padding-left: 2rem;
  line-height: 1.8;
}

.feature-list li {
  margin: 0.8rem 0;
  color: #4a5568;
}

.navigation {
  display: flex;
  justify-content: center;
  gap: 2rem;
  margin-top: 3rem;
}

.nav-link {
  padding: 0.8rem 1.5rem;
  background-color: #42b983;
  color: white !important;
  border-radius: 4px;
  text-decoration: none;
  transition: all 0.3s ease;
}

.nav-link:hover {
  background-color: #3aa876;
  transform: translateY(-2px);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

@media (max-width: 768px) {
  .container {
    padding: 1rem;
  }

  .main-title {
    font-size: 2rem;
  }

  .navigation {
    flex-direction: column;
    gap: 1rem;
    align-items: center;
  }
}
</style>
